
// BuildMovieDlg.h : header file
//

#pragma once



// CBuildMovieDlg dialog
class CBuildMovieDlg : public CDialog
{
// Construction
public:
	CBuildMovieDlg(CWnd* pParent = NULL);	// standard constructor

	INT32		m_imageWidth;
	INT32		m_imageHeight;

	INT32		m_imageWidthDefault;
	INT32		m_imageHeightDefault;

	INT32		m_fps;
	INT32		m_checkCurrentImageSize;

	CString		m_strMovieFilename;

	CStringArray	m_strArrayFilename;
	CSTLIntArray	m_arrayFrame;

// Dialog Data
	enum { IDD = IDD_BUILDMOVIE_DIALOG };

	protected:
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support


// Implementation
protected:
	HICON m_hIcon;

	// Generated message map functions
	virtual BOOL OnInitDialog();
	afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	DECLARE_MESSAGE_MAP()

	void OnCurrentImageSize();
	void OnButtonSaveFilenameBrowse();
	void OnButtonInsert();
	void OnButtonRemove();
	void OnButtonUp();
	void OnButtonDown();
	void OnButtonCheckMovieSize();

public:
	afx_msg void OnFileNew();
	afx_msg void OnFileOpen();
	afx_msg void OnFileSave();
	afx_msg void OnButtonBuildMovie();

	afx_msg void OnFileExit();
	afx_msg void OnUpdateButtonBuildMovie(CCmdUI *pCmdUI);
	afx_msg void OnHelpAbout();

private:
	HRESULT MakeMovieWithImages(CString movieFilename, CStringArray & strArrayFilename, CSTLIntArray & arrayFrame, 
													INT32 width, INT32 height, INT32 fps , 
													BOOL & bFinished, INT32 & appendMovieIndex );

	INT32	GetAvailableMemoryMB();
public:
	afx_msg void OnDestroy();
};
